<?php


namespace app\admin\controller;


use Firebase\JWT\JWT;

class Pubilc {

	 static function check_jwt($jwt) {
		$key = "example_key";
		try{
			$decoded = JWT::decode($jwt, $key, array('HS256'));
			return $result=$decoded;
		}catch (\Firebase\JWT\ExpiredException $e){
			return $result=false;
		}catch (\UnexpectedValueException $e){
			return $result=false;
		}
	}


}